import request from '@/utils/request'

// 查询项目物资阈值设置列表
export function listMaterial(projectId) {
  return request({
    url: '/cld/material/list/'+projectId,
    method: 'get'
  })
}

// 查询项目物资阈值设置详细
export function getMaterial(projectMaterialId) {
  return request({
    url: '/cld/material/' + projectMaterialId,
    method: 'get'
  })
}

// 新增项目物资阈值设置
export function addMaterial(data) {
  return request({
    url: '/cld/material',
    method: 'post',
    data: data
  })
}

// 修改项目物资阈值设置
export function updateMaterial(data) {
  return request({
    url: '/cld/material',
    method: 'put',
    data: data
  })
}

// 删除项目物资阈值设置
export function delMaterial(projectMaterialId) {
  return request({
    url: '/cld/material/' + projectMaterialId,
    method: 'delete'
  })
}
